<?php 
class userdata_model extends CI_Model {

    function __construct() {
        
    }
    
        function get_userdata($username = '') {
            $this->db->where('username', $username);
            $data = $this->db->get('users')->row();
            return $data;
        
    }

}
?>